package io.renren.modules.equipment;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class EquipmentServiceImpl extends ServiceImpl<EquipmentDao, EquipmentEntity> implements EquipmentService {

  @Override
  public List<EquipmentEntity> listByBuildingId(String buildingNo) {
    QueryWrapper<EquipmentEntity> queryWrapper = new QueryWrapper<>();
//    queryWrapper.eq("building_id", buildingNo);
    queryWrapper.eq("deleted", 0);
    queryWrapper.orderByAsc("id");
    return list(queryWrapper);
  }
}
